﻿using System;
using System.Collections.Generic;
using System.Linq;
using SqlSugar;
namespace ZR.Model.mes.md
{
    /// <summary>
    /// 线体
    ///</summary>
    [SugarTable("md_workline")]
    public class MdWorkline
    {
        /// <summary>
        /// 流水号 
        ///</summary>
         [SugarColumn(ColumnName="id" ,IsPrimaryKey = true ,IsIdentity = true  )]
         public int Id { get; set; }
        /// <summary>
        /// 线体code 
        ///</summary>
         [SugarColumn(ColumnName="line_code"    )]
         public string LineCode { get; set; }
        /// <summary>
        /// 线体名称 
        ///</summary>
         [SugarColumn(ColumnName="line_name"    )]
         public string LineName { get; set; }
        /// <summary>
        /// fk_工作车间
        ///</summary>
         [SugarColumn(ColumnName= "pk_workshop_id")]
         public int? FkWorkShopId { get; set; }


        [Navigate(NavigateType.OneToOne, nameof(FkWorkShopId))]//一对一 SchoolId是StudentA类里面的
        public MdWorkshop  Workshop { get; set; } //不能赋值只能是null
        /// <summary>
        /// 租户号 
        ///</summary>
        [SugarColumn(ColumnName="TENANT_ID"    )]
         public string TenantId { get; set; }
        /// <summary>
        /// 乐观锁 
        ///</summary>
         [SugarColumn(ColumnName="REVISION"    )]
         public int? Revision { get; set; }
        /// <summary>
        /// 创建人 
        ///</summary>
         [SugarColumn(ColumnName="CREATED_BY"    )]
         public string CreatedBy { get; set; }
        /// <summary>
        /// 创建时间 
        ///</summary>
         [SugarColumn(ColumnName="CREATED_TIME"    )]
         public DateTime? CreatedTime { get; set; }
        /// <summary>
        /// 更新人 
        ///</summary>
         [SugarColumn(ColumnName="UPDATED_BY"    )]
         public string UpdatedBy { get; set; }
        /// <summary>
        /// 更新时间 
        ///</summary>
         [SugarColumn(ColumnName="UPDATED_TIME"    )]
         public DateTime? UpdatedTime { get; set; }
    }
}
